if (TARGET hardware_i2c)
    add_subdirectory_exclude_platforms(bmp280_i2c)
    add_subdirectory_exclude_platforms(bus_scan)
    add_subdirectory_exclude_platforms(lcd_1602_i2c)
    add_subdirectory_exclude_platforms(lis3dh_i2c)
    add_subdirectory_exclude_platforms(mcp9808_i2c)
    add_subdirectory_exclude_platforms(mma8451_i2c)
    add_subdirectory_exclude_platforms(mpl3115a2_i2c)
    add_subdirectory_exclude_platforms(mpu6050_i2c)
    add_subdirectory_exclude_platforms(ssd1306_i2c)
    add_subdirectory_exclude_platforms(pa1010d_i2c)
    add_subdirectory_exclude_platforms(pcf8523_i2c)
    add_subdirectory_exclude_platforms(ht16k33_i2c)
    add_subdirectory_exclude_platforms(slave_mem_i2c)
else()
    message("Skipping I2C examples as hardware_i2c is unavailable on this platform")
endif()
